package com.feiyuan.core.service;

import com.feiyuan.core.pojo.entity.AdminRole;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

public interface AdminRoleService extends IService<AdminRole> {
    /**
     * 查询所有角色信息
     * @param pageNo
     * @param pageSize
     * @param roleName
     * @param roleCode
     * @return
     */
    IPage<AdminRole> listPage(Integer pageNo, Integer pageSize, String roleName, String roleCode);

    /**
     * 保存或编辑
     * @param adminRole
     * @return
     */
    boolean saveOrUpdateRole(AdminRole adminRole);

    /**
     * 查询用户对应的角色
     * @return
     */
    List<String> selectRoles(Long userId);
}
